package com.iqiyi.pps.epg.core.model.record;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

import javax.persistence.*;
import java.sql.Timestamp;

/**
 * Created by hejia on 2018/4.
 */
@Entity
@Table(name = "record_video")
@Cache(usage = CacheConcurrencyStrategy.NONE)
public class RecordVideo {
    private long id;
    private long channelId;
    private long channelSignalId;
    private long signalId;
    private long taskId;
    private long videoId;
    private int videoStatus;
    private Timestamp updateTime;
    private Timestamp createTime;
    private int status;



    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }


    @Column(name = "channel_id")
    public long getChannelId() {
        return channelId;
    }

    public void setChannelId(long channelId) {
        this.channelId = channelId;
    }

    @Column(name = "channel_signal_id")
    public long getChannelSignalId() {
        return channelSignalId;
    }

    public void setChannelSignalId(long channelSignalId) {
        this.channelSignalId = channelSignalId;
    }

    @Column(name = "signal_id")
    public long getSignalId() {
        return signalId;
    }

    public void setSignalId(long signalId) {
        this.signalId = signalId;
    }

    @Column(name = "task_id")
    public long getTaskId() {
        return taskId;
    }

    public void setTaskId(long taskId) {
        this.taskId = taskId;
    }

    @Column(name = "video_id")
    public long getVideoId() {
        return videoId;
    }

    public void setVideoId(long videoId) {
        this.videoId = videoId;
    }

    @Column(name = "video_status")
    public int getVideoStatus() {
        return videoStatus;
    }

    public void setVideoStatus(int videoStatus) {
        this.videoStatus = videoStatus;
    }

    @Column(name = "create_time")
    public Timestamp getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }

    @Column(name = "update_time", insertable = false, updatable = false)
    public Timestamp getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Timestamp updateTime) {
        this.updateTime = updateTime;
    }

    @Column(name = "status")
    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }


    @Override
    public String toString() {
        return "RecordVideo{" +
                "id=" + id +
                ", channelId=" + channelId +
                ", channelSignalId=" + channelSignalId +
                ", signalId=" + signalId +
                ", taskId=" + taskId +
                ", videoId=" + videoId +
                ", videoStatus=" + videoStatus +
                ", updateTime=" + updateTime +
                ", createTime=" + createTime +
                ", status=" + status +
                '}';
    }
}
